﻿(function() {
    var submitVet = function(){
        var clinicNameInput = document.getElementById("clinicname");
        var clinicName = clinicNameInput.value;

        var addressInput = document.getElementById("address");
        var address = addressInput.value;

        var vetNameInput = document.getElementById("vetname");
        var vetName = vetNameInput.value;

        var phoneInput = document.getElementById("phone");
        var phone = phoneInput.value;

        ViewModels.addVet(clinicName, address, vetName, phone);
    }

    WinJS.Utilities.markSupportedForProcessing(submitVet);

    WinJS.Namespace.define("AddVeterinaryCodeBehind", {
        submitVet: submitVet
    });
})()